package api

import (
	"net/http"
	"fmt"
	"go-web/web"
)

func BookHandler() web.WebHandler {
	return func(writer http.ResponseWriter, request *http.Request) {
		writer.Header().Set("Content-Type", "application/json")
		request.ParseForm()
		method := request.Method
		if method == GET {
			idStr := request.Form.Get(ID)
			if idStr == "" {
				fmt.Println("error id")
			}
			fmt.Println(idStr + "===")
		}
	}
}
